<template>
  <div class="result">
    <head-top head-title="房屋认证结果" goBack="true"></head-top>
    <div class='head'>
      <span>认证的房屋</span>
    </div>
    <div class="home_show">
      <ul>
        <li class="border-bottom">
          <span>小区：</span>
          <span>{{list.title}}</span>
        </li>
        <li>
          <span>房屋：</span>
          <span>{{list.yuan}}{{list.zhuang}}幢{{list.danyuan}}单元{{list.fanghao}}</span>
        </li>
      </ul>
    </div>
    <div class='head'>
      <span>结果</span>
    </div>
    <div class="result_show">
      <ul>
        <li class="border-bottom">
          <span>进度：</span>
          <span>{{list.progress}}</span>
        </li>
        <li class="border-bottom">
          <span>状态：</span>
          <span v-html="list.flag ? '开启' : '关闭'"></span>
        </li>
        <li class="border-bottom">
          <span>信息：</span>
          <span>{{list.reply_message}}</span>
        </li>
      </ul>
    </div>
  </div>
</template>
<style lang="scss">

  .result {
    padding-top: 40px;
    .head {
      background: #f4f4f4;
      span {
        font-size: 15px;
        line-height: 44px;
        margin-left: 10px;
      }
    }
    .home_show {
      background: #fff;
      ul {
        li {
          margin: 0 10px;
          line-height: 44px;
          span:first-child {
            font-size: 15px;
          }
          span:last-child {
            font-size: 14px;
            float: right;
            color: #777;
          }
        }
        li:last-child{
          border-bottom: none;
        }
      }
    }
    .result_show {
      background: #fff;
      ul {
        li {
          margin: 0 10px;
          line-height: 44px;
          span:first-child {
            font-size: 15px;
          }
          span:last-child {
            font-size: 14px;
            float: right;
            color: #777;
          }
        }
        li:last-child{
          border-bottom: none;
        }
      }
    }
  }
</style>
<script>
  import headTop from '../header/Header.vue'
  import commonUrl from '../../common/js/commonUrl.js'
  export default {
    name: 'Result',
    data () {
      return {
        list: ''
      }
    },
    created() {
      this.getResultData()
    },
    methods: {
      getResultData() {
        const url = commonUrl.apihost + 'index.php/home/house_Auth/getOneHouse?id=' + this.$route.params.id
        this.$http.get(url).then(res => {
          if (res.data.code === 200) {
            this.list = res.data.data[0]
          }
        })
      }
    },
    components: {
      headTop
    }
  }
</script>
